Skip to content

Conversation

ARandomDev99
Copy link
Contributor

@ARandomDev99 ARandomDev99 commented May 16, 2025

Fixes #14688

If you added a new lint, here's a checklist for things that will be
checked during review or continuous integration.

  • Followed lint naming conventions
  • Added passing UI tests (including committed .stderr file)
  • cargo test passes locally
  • Executed cargo dev update_lints
  • Added lint documentation
  • Run cargo dev fmt
changelog: New lint: [`matches_instead_of_eq`]

TO DO: Modify code that causes the dogfood test to fail.

@ARandomDev99 ARandomDev99 changed the title New lint: matches_instead_of_eq [WIP] New lint: matches_instead_of_eq May 16, 2025
@ARandomDev99
Copy link
Contributor Author

r? rust-lang/clippy

@ARandomDev99
Copy link
Contributor Author

I'll hold off making the dogfood test pass until there's some comment from the maintainers about whether the current UI test is sufficient and covers all cases.

@Jarcho
Copy link
Contributor

Jarcho commented May 21, 2025

This is essentially the same as equatable_if_let, but on matches!. It would be good to share most of the implementation.

@GuillaumeGomez
Copy link
Member

Hi. Any update here?

@ARandomDev99
Copy link
Contributor Author

Hi. I got busy with other things and forgot about this. I shall get back to it later this week. Apologies for any inconvenience.

@ARandomDev99
Copy link
Contributor Author

I'll be closing this WIP PR. The master branch has changed a lot and I've never been that great at rebasing so I'll open a fresh PR once I make my changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Suggest using == instead of matches!
3 participants